#ifndef __FLASH_FUNC_H__
#define __FLASH_FUNC_H__

int32_t get_sector_from_addr(uint32_t Address);

int8_t read_settings_boot_state(void);
int8_t write_settings_boot_state(uint8_t state);
int8_t read_settings_boot_partition(void);
int8_t write_settings_boot_partition(int8_t state);

uint32_t flash_erase(uint32_t StartAdd);
int8_t flash_write_continue(uint32_t StartAddress, uint32_t EndAddress,
							uint32_t* Data ,uint32_t DataLength);

#endif
